derivative of implicit function